package mil.af.amc.adpetracker.service;

import mil.af.amc.adpetracker.model.Authority;
import mil.af.amc.adpetracker.dao.AuthorityDao;

import java.util.List;

/**
 * Implementation of Authority Service
 *
 * @author TSgt Jason Ferguson
 */

public class AuthorityServiceImpl implements AuthorityService {

    private AuthorityDao authorityDao;

    public void setAuthorityDao(AuthorityDao authorityDao) {
        this.authorityDao = authorityDao;
    }

    public List<Authority> getAll() {
        return authorityDao.getAll();
    }

    public Authority getAuthorityByName(String name) {

        return authorityDao.getByName(name);
    }
}
